#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
const int mod = 1e9 + 7;

int gcd(int a, int b)
{
    return b ? gcd(b, a % b) : a;
}

ll qmi(ll a, ll b)
{
    ll res = 1;
    while(b)
    {
        res = res * a % mod;
        b >>= 1;
        a = a * a % mod;
    }
    return res;
}

void solve()
{
    int n, m, k;
    cin >> n >> m >> k;
    string s;
    cin >> s;
    s = 'L' + s;
    s += 'L';
    vector<int>L;
    for(int i = 0; i < s.size(); i++)
        if(s[i] == 'L')L.push_back(i);
    bool ok = true;
    int cnt = 0;
    for(int i = 1; i < L.size(); i++)
    {
        
        if(L[i] - L[i - 1] > m)
        {
            for(int j = L[i - 1] + m; j <= L[i]; j++)
            {
                if(s[i] == 'C'){
                    ok = false;
                    break;
                }
                if(s[i] == 'W')
                    cnt++;
            }
        }
        if(!ok || cnt > k)break;
    }
    if(cnt > k) ok = false;
    if(ok) cout << "YES\n";
    else cout << "NO\n";

}

int main()
{
    int t;
    cin >> t;
    while(t--) solve();
    return 0;
}